package com.xiao.springaopdemo1;

import com.xiao.springaopdemo1.xml.Calculator;
import org.junit.jupiter.api.Test;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class AOPxml {
    @Test
    public void method(){
        ApplicationContext ioc = new ClassPathXmlApplicationContext("AOP-xml.xml");
        Calculator bean = ioc.getBean(Calculator.class);
        int add = bean.add(1, 2);
        System.out.println(add);
    }
}
